This is a sample search file for use with Lasso. Lasso is used in conjunction with Mac OS Web servers to publish FileMaker Pro databases on the web.
Lasso is a product of Blue World Communications, Inc. Information is available at http://www.blueworld.com/lasso/
Lasso operates by interpreting 'Lasso Tags' placed in HTML 'format' files such as this. There are five types of Lasso tags: action, command, substitution, container, and sub-container. Lasso action and command tags are preceded by a dash. While substitution, container, and sub-container are surrounded by square brackets. All Lasso tags are not case sensitive. That is, Lasso will recognize "-DATABASE" or "-database" "-DaTaBaSe"; or [server_date], [SERVER_DATE], or [SeRveR_dAtE].
<h2>Lasso: Search the Sample Employees Database</h2>
</center>
<P align="center">This is an example of how to use Lasso to search a FileMaker Pro database.
<P align="center">The name of this file is
<strong>Search3.html</strong>; you'll find useful comments in it.
<center>
<!--
The inline tag is used to specify the Lasso action that is to occur. In this case it is simply the "show" action which instructs Lasso to gather information from the specified database.
<!-- Setting action="action.lasso" causes the Web server to direct processing to the Lasso Plug-in or Server. The slash indicates that the Lasso application is located at the root level and all format files should be specified from that location. Without the slash all format files are relative to the base URL-->
<form action="action.lasso" method="POST">
<!-- The "database" tag tells Lasso which FileMaker Pro database to use; the name is not case sensitive. This tag is required. -->
<!-- The "layout" tag tells Lasso which layout in the database to use; the name is not case sensitive. Specifying a layout is optional; if omitted, Lasso will use layout 0 of the database.
If specified, the layout must contain all fields specified in this form, AND all fields specifed in the format file (see discussion of the "-response" tag, below).
Specifying a layout is faster than using layout 0 because Lasso retrieves data for all fields in the layout, even if they're not used in the result page format file. Letting Lasso default to layout 0 is less error prone because it uses all fields in the database. -->
<!-- The -noResults tag specifies an HTML file for Lasso to display if no records are found as a result of the search. This field is optional. If omitted, Lasso displays a default "No Results" page. -->
<!-- Below here are the input fields for the search values. The names must match the FileMaker Pro field names exactly, but are not case sensitive. Any field can be left blank to tell Lasso to ignore that field.
The [operator] or -operator command tag, which can also be abbreviated [op] or -op, tells Lasso how to compare the value field to find matches. The default is "begins with" (similar to FileMaker Pro's default search operator). If an option list is specified, the default value is the first
<option> item in the list, unless the attribute 'selected' is used to indicate the default. You may also use operator in a hidden input field if you'd like. The -operator tag only affects the search field that immediately follows. It defaults back to "begins with" after that search field.
The values for -operator must appear exactly as in this example, but are not case sensitive. Alternately, abbreviations may be used for the operator values may be specified in the option tag. This allows use of alternate text to display to the end user. This example uses Lasso abbreviations for the operator values (German translations provided by Marco Galli):
<select name="-operator">
<option value="eq"> ist gleich
<option value="ct"> enthält
<option value="bw"> beginnt mit
<option value="ew"> endet mit
<option value="gt"> grösser als
<option value="gte"> grösser als oder gleich
<option value="lt"> kleiner als
<option value="lte"> kleiner als oder gleich
</select>
This form shows examples of text input, menus, and radio buttons to specify field values. -->
<!-- The operators "contains", "begins with", and "ends with" don't make sense for numeric fields, therefore we don't offer them as options here. Note the use of the HTML encodings > for > and < for
<!-- The [option: Field Name] tag can be used to format fields that contain value lists as HTML pop-up/pull-down menus. Lasso will substitute HTML in the form:
<option>List Value
for every value in the value list. Note that a "blank" selection is provided in the pop-up menu so that the user can choose not to specify a value for this field. -->
<!-- Field-level operators are possible using the "-opbegin" and "-opend" tags to specify that whatever is selected for this particular entry, not be included in this search. It is also possible to include two fields and require that they both be included (an "and" logical operator) while the rest of the search form uses the "or" logical operator. -->
<!-- The [value_list: Field Name] tag can be used to format fields that contain value lists as a set of radio buttons or checkboxes. All HTML between the [value_list: Field Name] and [/value_list] tags is repeated for every value in the value list. The actual list value is substitued for the [list_value] tag. -->
<!-- Searches on numeric and date ranges can be accomplished by providing two values for the field with appropriate comparison operators. Note that an operator must be used with fields that are defined as date or time and that only the equals, greater than (equals), or less than (equals) opertors can be used with these type of fields. -->
<!-- The "logicalop" tag can be used to specify whether Lasso performs an AND or an OR search for all field values. This is an optional tag; if not specified, the default is AND. -->
<!-- The "maxRecords" tag limits the number of records returned by Lasso. Specifying "all" tells Lasso to return all records. There is no limit imposed by Lasso on the number of records that can be returned. However, a perception of faster performance will be given by returning a small number of records, and using "[next]" links to view successive pages. See the file "hitlist_format.html" for a discussion of "[next]" links.
The 72K byte limit can be increased by increasing the memory partition in the "Get Info" box for the Web Server. -->
<td><b>Return</b>
<select name="-maxRecords">
<option>5
<option selected>10
<option>20
<option>30
<option>50
<option>all
</select>
<b>records per page
</td>
</tr>
<!-- The "sortfield" tag tells Lasso which field to sort the results on. It is optional. The value of "Unsorted" (not case sensitive) is recognized by Lasso or the field can be left without any value to leave records unsorted.
There is no limit to the number of sort fields that can be specified by the "sortfield" tag. If multiple tags appear, the sorts will be nested in the order in which they appear on the search form. -->
<!-- The -sortordertag applies to the immediately preceding -sortfield. This tag is optional and defaults to "ascending". The value "custom" can be used for fields that contain value list to sort in value list order. -->
<!-- The "response" tag tells Lasso which format file to use for formatting output. There can be one or more hitlist format files to display the search results. And, the user can be given the option to select which hitlist format file to display. For example, you could have a long form to display a lot of fields, and a short form to display limited fields for a set of records. The following syntax shows how to creating radio buttons for selecting the preferred hitlist.
Alternately, the "response" tag can be specified in a hidden input field if no choice is to be given to the user for formatting search results. -->
<!-- Clicking the "search" button causes Lasso to conduct a database search based on the criteria specified by the user in this form. The value of this button can be anything. -->
<!-- Clicking the "findall" button causes Lasso to return all records in the database, regardless of the criteria specified in this form. The "sortfield," "sortorder," and "maxRecords" values will be applied to the returned records. The value of this button can be anything. -->
<!-- The reset button has no effect on Lasso, it merely clears the current form. Reset does not change field information stored in the FileMaker Pro database -->
<input type="Reset" value="Clear this form">
</form>
</center>
<!-- The [include] tag instructs Lasso to parse and insert the output HTML from the specified format file into the HTML for this format file. -->